// 示例：编辑模式切换
document.querySelectorAll('.edit-trigger').forEach(button => {
    button.addEventListener('click', () => {
        const formGroup = button.closest('.form-group');
        formGroup.classList.toggle('edit-mode');
    });
});

// 示例：导航菜单激活状态
document.querySelectorAll('.nav-link').forEach(link => {
    link.addEventListener('click', (e) => {
        e.preventDefault();
        document.querySelector('.nav-link.active').classList.remove('active');
        link.classList.add('active');
        document.querySelector(link.getAttribute('href')).scrollIntoView({
            behavior: 'smooth'
        });
    });
});
